Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make changes for public organization mediafiles #146

Merged
merged 15 commits into from
Sep 10, 2024

Conversation

luisa-beerboom
Copy link
Member

Closes #121

Copy link
Member

@r-peschke r-peschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only some questions/remarks

@@ -2196,7 +2205,7 @@ list_of_speakers:
- motion_block
- assignment
- topic
- mediafile
- meeting_mediafile
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why you can't stay with the mediafile? The permission was checked on assigning the mediafile to an object.
What kind of permission will be checked on usage of the object? If user A has the right to see a mediafile, he can assign the mediafile to a list_of_speakers and to a motion.
If user B is not allowed to see this mediafile, is he forced to see the list_of_speakers without the grafik-icon? On a motion's attachment this may have a sense, on speakers-list not, assuming the mediafile is used as a kind of icon for the speakers list or another object.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't get what this has to do with permissions, however the reasons I moved all these fields to their own model are:

  1. To make backend-side meeting-related-mediafile-data-management easier. If, for example, a published orga mediafile's access groups are edited in a meeting, the re-calculation of inherited access groups for this mediafile and its descendants doesn't call for reconsideration of the inherited access groups that are set in any other meetings. It would make no sense at all to juggle endlessly long lists of access groups even though usually only about 3 of them are relevant and may need to be changed at a time.
  2. To make client-side display easier. For example: If the client wants to display in the mediafile list, whether a mediafile is being projected in this meeting, he shouldn't have to filter through a list of 300 current projections just to see if one of them is from this meeting.
  3. To keep integrity checks easier. Using the meeting-internal meeting_mediafile model allows us to keep the equal_fields: meeting_id requirement for these relations, which would definitely have to be removed, if we used the base mediafile model since, due to the new "publishing" feature, it can now have an organization owner, even if it is used in a meeting context. However meeting_mediafile always has a distinct meeting_id

Does that answer your questions?

@@ -2393,7 +2402,7 @@ topic:

attachment_ids:
type: relation-list
to: mediafile/attachment_ids
to: meeting_mediafile/attachment_ids
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see above

@@ -2673,7 +2682,7 @@ motion:
restriction_mode: C
attachment_ids:
type: relation-list
to: mediafile/attachment_ids
to: meeting_mediafile/attachment_ids
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see above

@@ -3574,7 +3583,7 @@ assignment:
restriction_mode: A
attachment_ids:
type: relation-list
to: mediafile/attachment_ids
to: meeting_mediafile/attachment_ids
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see above

models.yml Show resolved Hide resolved
models.yml Outdated
restriction_mode: A
inherited_access_group_ids:
type: relation-list
to: group/mediafile_inherited_access_group_ids
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think of explaining the calculation rules here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea, will do just that.

@peb-adr peb-adr merged commit 8e74514 into OpenSlides:main Sep 10, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow orga-files/folders to be accessible in meetings
4 participants